package com.jy.adscm.operation.hscrb.service.impl;

import com.baomidou.mybatisplus.mapper.EntityWrapper;
import com.baomidou.mybatisplus.mapper.Wrapper;
import com.jy.adscm.operation.hscrb.bean.HyFreightdetail;
import com.jy.adscm.operation.hscrb.mapper.mysql.HyFreightdetailMapper;
import com.jy.adscm.operation.hscrb.service.HyFreightdetailService;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author zyl
 * @since 2018-12-13
 */
@Service
public class HyFreightdetailServiceImpl extends ServiceImpl<HyFreightdetailMapper, HyFreightdetail> implements HyFreightdetailService {

    @Override
    public Boolean updateHyFreightdetail(HyFreightdetail hyFreightdetail) {

        boolean b = super.updateById(hyFreightdetail);
        return b;
    }

    @Override
    public List<HyFreightdetail> selectByTid(String tid) {
        Wrapper<HyFreightdetail>  wrapper =new EntityWrapper<>();
        wrapper.eq("TID",tid);
        List<HyFreightdetail> hyFreightdetails = super.selectList(wrapper);
        return hyFreightdetails;
    }
}
